package com.cplatform.movie.back.store.entity;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.codehaus.jackson.annotate.JsonProperty;

/**
 * Title. 商户表<br>
 * Description.
 * <p>
 * Copyright: Copyright (c) 2015年6月25日 下午5:48:36
 * <p>
 * Company: 北京宽连十方数字技术有限公司
 * <p>
 * Author: liuyt@c-platform.com
 * <p>
 * Version: 1.0
 * <p>
 */
@Entity
@Table(name = "T_STORE")
public class Store implements Serializable {

	public static Map<Long, String> statusMap = null;

	static {
		statusMap = new HashMap<Long, String>();
		statusMap.put(0l, "未审核");
		statusMap.put(1l, "待审核");
		statusMap.put(3l, "审核通过");
		statusMap.put(4l, "审核驳回");
	}

	private Long id;

	/** 帐号登陆用户ID**/
	private Long sysUserId;
	
	/** 商户名称 **/
	private String name;

	/** 归属地市 **/
	private String areaCode;

	/** 归属地市 **/
	private String areaName;

	/** 创建时间 **/
	private String createTime;

	/** 商户地址 **/
	private String address;

	private String email;

	/** 商户状态 0--未审核 1--待审核 2--审核驳回 3--审核通过 **/
	private Long status;

	/** 商户是否有效 0--无效 1--有效 **/
	private Long isValid;
	
	/** 商户图片**/
	private String imgPath;

	@SequenceGenerator(name = "seq_store", sequenceName = "SEQ_STORE")
	@Id
	@GeneratedValue(generator = "seq_store")
	@JsonProperty
	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	/** 联系电话 **/
	private String linkPhone;
	
	/** 联系人**/
	private String linkName;

	@Column(name = "NAME", length = 50)
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Column(name = "AREA_CODE", length = 10)
	public String getAreaCode() {
		return areaCode;
	}

	public void setAreaCode(String areaCode) {
		this.areaCode = areaCode;
	}

	@Column(name = "CREATE_TIME", length = 14)
	public String getCreateTime() {
		return createTime;
	}

	public void setCreateTime(String createTime) {
		this.createTime = createTime;
	}

	@Column(name = "ADDRESS", length = 100)
	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	@Column(name = "STATUS", precision = 1, scale = 0)
	public Long getStatus() {
		return status;
	}

	public void setStatus(Long status) {
		this.status = status;
	}

	@Column(name = "IS_VALID", precision = 1, scale = 0)
	public Long getIsValid() {
		return isValid;
	}

	public void setIsValid(Long isValid) {
		this.isValid = isValid;
	}

	@Column(name = "LINK_PHONE")
	public String getLinkPhone() {
		return linkPhone;
	}

	public void setLinkPhone(String linkPhone) {
		this.linkPhone = linkPhone;
	}

	/** 查询用创建开始时间 **/
	private String beginTime;

	/** 查询用创建结束时间 **/
	private String endTime;

	/**
	 * 审核时间
	 */
	private String auditTime;

	@Transient
	public String getBeginTime() {
		return beginTime;
	}

	@Transient
	public void setBeginTime(String beginTime) {
		this.beginTime = beginTime;
	}

	@Transient
	public String getEndTime() {
		return endTime;
	}

	@Transient
	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}

	@Transient
	public String getAreaName() {
		return areaName;
	}

	@Transient
	public void setAreaName(String areaName) {
		this.areaName = areaName;
	}

	@Transient
	public String getAuditTime() {
		return auditTime;
	}

	public void setAuditTime(String auditTime) {
		this.auditTime = auditTime;
	}

	@Column(name = "EMAIL")
	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	@Column(name = "SYS_USER_ID")
	public Long getSysUserId() {
		return sysUserId;
	}

	public void setSysUserId(Long sysUserId) {
		this.sysUserId = sysUserId;
	}

	@Column(name = "LINK_NAME")
	public String getLinkName() {
		return linkName;
	}

	public void setLinkName(String linkName) {
		this.linkName = linkName;
	}
	
	@Column(name="IMAGE_PATH")
	public String getImgPath() {
		return imgPath;
	}

	public void setImgPath(String imgPath) {
		this.imgPath = imgPath;
	}

	/** 后台帐号登陆名**/
	private String userName;
	
	@Transient
	public String getUserName() {
		return userName;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

}
